package com.core.gui.helper;

import com.core.entities.Contact;
import com.core.entities.Username;
import com.core.service.MainService;

public class UserInfo {
	
	private static UserInfo userInfo;
	private static Username user;
	private static MainService service;
	private static Contact contact;
	
	
	public UserInfo() {

		
	}
	
	
	public static UserInfo getInstance(){
		if(userInfo == null)
			userInfo = new UserInfo();
		return userInfo;
	}
	
	public void setUsername(Username user){
		this.user = user;
	}
	
	public Username getUser(){
		return user;
	}
	
	public String getUsername(){
		
		return getUser().getUsername();
		
//		return "ibrahim";
	}
	public MainService getService(){
		if(service == null)
			service = new MainService();
		return service;
	}


	public Contact getContact() {
		
		return contact;
	}
	public String getFirstName(){
		return "ibtrahim";
	}


	public void setContact(Contact contact) {
		UserInfo.contact = contact;
	}
	
	
	
	
	

}
